package com.qf.data.notify.entity;

import lombok.Data;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

/**
 * author Ken
 * create_time 2022/11/24
 */
@Data
@Accessors(chain = true)
public class Email implements Serializable {

    private String subject;
    private String from;
    private List<String> tos;
    private String content;

    {
        tos = new ArrayList<>();
    }

    public Email addTo(String to){
        this.tos.add(to);
        return this;
    }
}
